import logging
import yagmail

def log_connect():
    logging.basicConfig(filename='weidudiansanglog.txt',filemode='w+',level=logging.INFO,format='%(asctime)s***%(msecs)d***%(thread)d***%(levelname)s')

def email(filename):
    qq=yagmail.SMTP(user='2314336117@qq.com',password='ixpbgkkezjwodhif',host='smtp.qq.com')
    qq.send(to='2314336117@qq.com',subject='维度电商系统接口测试报告',contents='维度电商系统接口测试报告',attachments=filename)
